SmallParticle = class(Particle)
SmallParticle.onGroundSpeedDelay = 0.75
SmallParticle.speed = 0.15
SmallParticle.dispersed = 0.3
SmallParticle.life = 3

function SmallParticle:init(x,y,z,tex)
    x = x + (math.random() * 2 - 1) * 0.4
    y = y + (math.random() * 2 - 1) * 0.4 + 0.3
    z = z + (math.random() * 2 - 1) * 0.4
    xa,ya,za = 0,0,0
    Particle.init(self,x,y,z,xa,ya,za,tex)
    self.tex = tex
    self:setSize(0.1,0.1)
    self:setPos(x,y,z)
    
    self.xd = xa + (math.random() * 2 - 1) * 0.4
    self.yd = ya + (math.random() * 2 - 0.5) * 0.4
    self.zd = za + (math.random() * 2 - 1) * 0.4
    
    local speed = (math.random() + math.random() + 1) * SmallParticle.speed
    local dd = math.sqrt(self.xd * self.xd + self.yd * self.yd + self.zd * self.zd)
    self.xd = self.xd / dd * speed * SmallParticle.dispersed
    self.yd = self.yd / dd * speed * SmallParticle.dispersed + 0.02
    self.zd = self.zd / dd * speed * SmallParticle.dispersed

    
    self.size = math.random() * 0.2 + 0.3
    self.life = SmallParticle.life / (math.random() * 0.9 + 0.1)
    self.age = 0
end
